<!DOCTYPE html>  
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:th="http://www.thymeleaf.org"  
      xmlns:sec="http://www.thymeleaf.org/thymeleaf-extras-springsecurity4">
    <head>
        <title sec:authentication="name">Hello World!</title>
           <link rel="stylesheet" th:href="@{/resources/css/home.css}"/>
           <link rel="stylesheet" th:href="@{/resources/bootstrap-table-master/assets/bootstrap/css/bootstrap.min.css}"/>
               <script th:src="@{/resources/js/jquery-1.8.3.min.js}"></script>
                     <script th:src="@{/resources/js/common.js}"></script>
    <script type="text/javascript" th:src="@{/resources/bootstrap-table-master/assets/bootstrap/js/bootstrap.min.js}"></script>  
    </head>
    <body>

       


        <div sec:authorize="hasRole('ROLE_ADMIN')">
          <p>ROLE_ADMIN</p>
        </div>
        <div sec:authorize="hasRole('ROLE_USER')">
          <p>ROLE_USER</p>
        </div>
        <div sec:authorize="hasRole('ROLE_NEW')">
          <p>ROLE_NEW</p>
        </div>
            <div class="navbar navbar-duomi navbar-static-top" role="navigation">
        <div class="container-fluid">
            <div class="navbar-header" style="display:inline;">
                <a class="navbar-brand" href="#" id="logo"  th:inline="text">欢迎您[[${#httpServletRequest.remoteUser}]] 进入后台管理系统！
                </a>
                        <form th:action="@{/logout}" method="post" style="display:inline">
            <input type="submit" value="注销"/>
        </form>
            </div>
        </div>
    </div>

    <div class="container-fluid">
        <div class="row">
            <div class="col-md-2">
                <ul id="main-nav" class="main-nav nav nav-tabs nav-stacked" style="">
                    <li th:each="sysFunc:${sysFuncs}">
                        <a th:href="@{'#'+${sysFunc.url}}" class="nav-header collapsed" data-toggle="collapse">
                            <i class="glyphicon glyphicon-cog"></i>	
                            <span class="pull-right glyphicon glyphicon-chevron-toggle" th:text="${sysFunc.name}"></span>
                        </a>
                        <ul th:id="${sysFunc.url}" class="nav nav-list secondmenu collapse" style="height: 0px;">
                            <li  th:each="sysFuncSub:${sysFunc.sysFuncSubList}"><a th:href="${sysFuncSub.url}"><i class="glyphicon glyphicon-user" th:text="${sysFuncSub.name}"></i></a></li>
                       
                        </ul>
                    </li>
                    
                </ul>
            </div>
            <div class="col-md-10" >
                这里是内容
            </div>
              <div class="loading"></div>
        </div>
    </div>
        		<script type="text/javascript">

		$(document).ready(function() {
			$(".row ul li ul li a").not("[href^='#Setting']").click(function(){
				var curUrl = $(this).attr("href");
				loadContentPage(curUrl);
				return false;
			});
			
			});
			</script>
    </body>
</html>